// 导入模块 Import modules
import type { PlayerDataInterface } from '../interface/player';

/**
 * @zh 玩家初始数据
 * @param entity 玩家实体
 * @returns 返回玩家初始数据
 * @en Player initial data
 * @param entity Player entity
 * @returns Returns player initial data
 */
function playerInitData(entity: GamePlayerEntity): PlayerDataInterface {
    /**
     * @zh 请在此处编辑玩家初始数据
     * 可以调用：
     * - `entity`：玩家实体
     * @en Please edit player initial data here
     * You can call:
     * - `entity`: Player entity
     */
    const data: PlayerDataInterface = {
        name: entity.player.name,
        userId: entity.player.userId,
        action: '无',
        Open: [],
        level: 0,
        task: '',
        PrayTypes: [],
        PrayKeepsake: [],
        PraySentence: [],
        PrayIntegrity: 0,
        Prop: [],
        Soul: 1,
    };
    return data;
}

/**
 * @zh 虚拟接口
 * @en Virtual interface
 */
const VirtualPlayerDataInterface: PlayerDataInterface = {
    name: 'interface',
    userId: '000000000',
    action: '无',
    Open: ['open'],
    level: 0,
    task: 'task',
    PrayTypes: ['pray-types'],
    PrayKeepsake: ['pray-keepsake'],
    PraySentence: ['pray-sentence'],
    PrayIntegrity: 1,
    Prop: ['prop'],
    Soul: 2,
};

// 导出模块 Export modules
export { playerInitData, VirtualPlayerDataInterface };
